package com.usian.article.controller;

import com.usian.apis.article.ApCollectionControllerApi;
import com.usian.article.service.ApCollectionService;
import com.usian.model.article.dtos.CollectionBehaviorDto;
import com.usian.model.common.dtos.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/v1/collection")
public class ApCollectionController implements ApCollectionControllerApi {

    @Autowired
    private ApCollectionService apCollectionService;

    @Override/*保存 收藏*/
    @PostMapping("/saveApCollection")
    public ResponseResult saveApCollection(@RequestBody CollectionBehaviorDto dto) {
        return apCollectionService.saveApCollection(dto);
    }
}
